From: jeanlf Date: Tue, 1 Feb 2022 14:28:23 +0000 (+0100) Subject: [PATCH] fixed #2092 X-Git-Tag: archive/raspbian/1.0.1+dfsg1-4+rpi1+deb11u2^2~91 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=d340f95b7b127fd546f06e3c23060846d878a295;p=gpac.git [PATCH] fixed #2092 Gbp-Pq: Name CVE-2021-4043.patch --- diff --git a/src/isomedia/box_code_base.c b/src/isomedia/box_code_base.c index 280b351..4de52f0 100644 --- a/src/isomedia/box_code_base.c +++ b/src/isomedia/box_code_base.c @@ -10672,10 +10672,12 @@ void gitn_box_del(GF_Box *s) u32 i; GroupIdToNameBox *ptr = (GroupIdToNameBox *)s; if (ptr == NULL) return; - for (i=0; inb_entries; i++) { - if (ptr->entries[i].name) gf_free(ptr->entries[i].name); + if (ptr->entries) { + for (i=0; inb_entries; i++) { + if (ptr->entries[i].name) gf_free(ptr->entries[i].name); + } + gf_free(ptr->entries); } - if (ptr->entries) gf_free(ptr->entries); gf_free(ptr); }